home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 6086 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  932 b 

  1. Path: ulysses.midtown.net!news
  2. From: samwise@midtown.net (Rick)
  3. Newsgroups: comp.lang.c++
  4. Subject: C++ for loop
  5. Date: Sun, 11 Feb 1996 19:49:57 GMT
  6. Organization: 
  7. Message-ID: <4flhm3$t3a@ulysses.midtown.net>
  8. NNTP-Posting-Host: samwise.midtown.net
  9. X-Newsreader: Forte Agent .99a.107
  10.  
  11. I'm in my second week in a C++ programming class.  I like it, its a
  12. lot like Pascal.  I want to draw a box, so I converted an old Pascal
  13. routine that I wrote.   I can't find a good explanation on the   for
  14. command.  Wonder what I am doing wrong.  I hate to wait for Monday to
  15. ask.  This is what I am trying:
  16.  
  17. for(I=2;I >= 79;I++)
  18.     {
  19.          gotoxy(I,1);
  20.          printf("-"); // #205            print #205
  21.     };
  22. I want to do like a FOR NEXT in BASIC or For Do in Pascal. I want to
  23. count from 2 to 79 and store the incremented value each time in I,
  24. using it for my gotoxy() screen position
  25. Thanks
  26.  
  27.  
  28.  
  29. ...Give me back my data ya dirtbag machine!
  30.  
  31.